hysop.operator.integrate module¶
@file enstrophy.py Enstrophy solver frontend.
- class hysop.operator.integrate.Integrate(field, variables, parameter=None, scaling=None, base_kwds=None, expr=None, **kwds)[source]¶
Bases:
ComputationalGraphNodeFrontend
Interface for integrating fields on their domain Available implementations are:
*OPENCL (gpu based implementation)
Initialize a Integrate operator frontend.
Integrate a field on it compute domain and put the result in a parameter.
- in: field
Possibly as multi-component field that should be integrated.
- out: parameter
P = scaling * integral_V(field) where V is the field domain volume and scaling depends on specified scaling method.
parameter¶
- field: Field
Input continuous field to be integrated.
- variables: dict
dictionary of fields as keys and topologies as values.
- parameter: ScalarParameter or TensorParameter
The output parameter that will contain the integral. Should match field.nb_components. A default parameter will be created if not specified.
- scaling: None, float, str or array-like of str, optional
Scaling method used after integration. ‘volumic’: scale by domain size (product of mesh space steps) ‘normalize’: scale by first integration (first value will be 1.0) Defaults to volumic integration.
- expr: None, str, optional
expression performed on each entry of the array before sum, elements are referenced as x[i]
- implementation: Implementation, optional, defaults to None
target implementation, should be contained in available_implementations(). If None, implementation will be set to default_implementation().
- base_kwds: dict, optional, defaults to None
Base class keywords arguments. If None, an empty dict will be passed.
- kwds:
Extra keywords arguments that will be passed towards implementation enstrophy operator __init__.
Notes
An Integrate operator implementation should at least support the hysop.operator.base.integrate.IntegrateBase interface.